<%@ page language="java" import="java.util.*,java.sql.*" pageEncoding="UTF-8"%>
<%@ page import="java.text.SimpleDateFormat" %>
<%@include file="top.jsp"%>
<%@include file="left.jsp"%>
<%
    Connection dbcNews1 = db.getConnection();
	Statement stmtNews1 = dbcNews1.createStatement();
	String sqlNews1 = "SELECT top 7 n.newsid,n.title,n.createdate,c.catalogname FROM news AS n, catelog AS c WHERE n.catalogid=c.catalogid";
	ResultSet rsNews1 = stmtNews1.executeQuery(sqlNews1);
	
	
	Connection dbcq = db.getConnection();
	Statement stmtq = dbcq.createStatement();
	String sqlq = "SELECT top 7 d.desid,d.name,d.createdate,e.emotionname FROM desination AS d, emotion AS e WHERE d.emotionid=e.emotionid";
	ResultSet rsq= stmtq.executeQuery(sqlq);
	
	Connection dbcd1 = db.getConnection();
	Statement stmtd1 = dbcd1.createStatement();
	String sqld1 = "SELECT top 7 d.desid,d.name,d.createdate,b.timename FROM desination AS d, bustime AS b WHERE d.timeid=b.timeid";
	ResultSet rsd1 = stmtd1.executeQuery(sqld1);
 %>
<div id="content" class="align-right">
				<div id="content-top">
					<div id="content-top-left" class="align-left">
						<div id="slider" class="nivoSlider">
							<a href="#"><img src="images/upload/s000001.jpg" alt="" title="这里是第1幅画的介绍"/></a>
							<a href="#"><img src="images/upload/s000002.jpg" alt="" title="这里是第2幅画的介绍" /></a>
							<a href="#"><img src="images/upload/s000003.jpg" alt="" title="这里是第3幅画的介绍"/></a>
							<a href="#"><img src="images/upload/s000004.jpg" alt="" title="这里是第4幅画的介绍" /></a>
							<a href="#"><img src="images/upload/s000005.jpg" alt="" title="这里是第5幅画的介绍"/></a>
						</div>
						<div id="fashion-sign">
							<div id="scroller_roll1" class="scroller_roll">
							<ul>
								<li><a href="#" title="title1"><img src="./images/upload/mar000001.jpg" width="90" height="120" alt="title"/></a></li>
								<li><a href="#" title="title2"><img src="./images/upload/mar000001.jpg" width="90" height="120" alt="title"/></a></li>
								<li><a href="#" title="title3"><img src="./images/upload/mar000001.jpg" width="90" height="120" alt="title"/></a></li>
								<li><a href="#" title="title4"><img src="./images/upload/mar000001.jpg" width="90" height="120" alt="title"/></a></li>
							</ul>
							<div style="clear: both"></div>
							</div>
						</div>
					</div>
					<div id="content-top-right" class="align-right">
						<div id="user">
							<ul>
								<li><a id="login" href="./admin/login.jsp"><span>登录</span></a></li>
								<li><a id="reg" href="./admin/login_action.jsp"><span>注册</span></a></li>
								<li><a id="share" href="#"><span>分享</span></a></li>
							</ul>
						</div>
						<div id="tab-food-enter">
							<ul id="menu" class="menu">
								<li class="active"><a href="#food">餐饮美食</a></li>
								<li><a href="#enter">休闲娱乐</a></li>
							</ul>
							<div id="food" class="content">
								<p >
									 家常菜|面、快餐|火锅|烧烤、西餐|自助餐|江浙菜<br/>
									川菜|粤菜|湘菜|鲁菜|闽菜|东北菜|京菜|日韩菜<br/>
									东南亚菜|海鲜|清真|小吃|冷饮|甜食|其它
								</p>
							</div>
							<div id="enter" class="content">
								<p>

									测试<br />
								</p>
							</div>
						</div>
							
						<div id="tab-info-map-cut">
							<ul id="menu2" class="menu">
								<li class="active"><a href="#city">城市情报</a></li>
								<li><a href="#map">情绪地图</a></li>
								<li><a href="#leisure">休闲快捷</a></li>
							</ul>
							<div id="city" class="content">
								<ul>
								<%while(rsNews1.next()){ 
								java.util.Date date1=rsNews1.getDate("createdate");
	                            //SimpleDateFormat sf = new SimpleDateFormat("yyyy-MM-dd"); 
	                             %>
									<li><a href="event.jsp?newsid=<%=rsNews1.getInt("newsid")%>">[<%=rsNews1.getString("catalogname") %>]：<%=rsNews1.getString("title") %><%=date1%></a></li> 
								<%} %>									
								</ul>
							</div>
							<div id="map" class="content">
								
								<ul>
                                  <%while(rsq.next()){ 
                                  java.util.Date date2=rsq.getDate("createdate");%>                                  
									<li><a href="dest_info.jsp?desid=<%=rsq.getInt("desid")%>">[<%=rsq.getString("emotionname") %>]：<%=rsq.getString("name") %><%=date2%></a></li> 
								<%} %>						
								</ul>	
								
							</div>
							<div id="leisure" class="content">
								
								<ul>
                                 <%while(rsd1.next()){ 
                                 java.util.Date date3=rsd1.getDate("createdate");%>
									<li><a href="dest_info.jsp?desid=<%=rsd1.getInt("desid")%>">[<%=rsd1.getString("timename") %>]：<%=rsd1.getString("name") %><%=date3%></a></li> 
								<%} %>						
								</ul>	
								
							</div>
						</div>
					</div>
				</div>
				<div id="content-ads">
					<img src="images/ads_2.png" width="800" height="90" />
				</div>
				<div id="content-bot">
					<div id="content-bot-2"><br/>
						<div id="vogue" class="align-left">
							<h4>时尚中人</h4>
							<ul>
								<li><a href="#"><img src="images/fashion_guy_1.jpg"/> 米兰</a></li>
								<li><a href="#"><img src="images/fashion_guy_1.jpg"/> 米兰</a></li>
								<li><a href="#"><img src="images/fashion_guy_1.jpg"/> 米兰</a></li>
								<li><a href="#"><img src="images/fashion_guy_1.jpg"/> 米兰</a></li>
								<li><a href="#"><img src="images/fashion_guy_1.jpg"/> 米兰</a></li>
							</ul>
						</div>
						<div id="tags" class="align-right">
							<h4>热门标签</h4>
							<embed tplayername="SWF" splayername="SWF" type="application/x-shockwave-flash" src="flash/tagcloud.swf?r=8269298" mediawrapchecked="true" pluginspage="http://www.macromedia.com/go/getflashplayer" id="tagcloudflash" name="tagcloudflash" bgcolor="#ffffff" quality="high" wmode="transparent" allowscriptaccess="always" flashvars="tcolor=0xffffff&amp;tcolor2=0x999999&amp;hicolor=0xffffff&amp;tspeed=100&amp;distr=true" width="237" height="160">
						</div>
					</div>
				</div>
			</div>
			<%
			rsNews1.close();
			rsd1.close();
			rsq.close();
			dbcNews1.close();
			dbcd1.close();
			dbcq.close();
			
			 %>
<script type="text/javascript">
	
	$(document).ready(function(){
		
		/*选中，如下*/
		$('#li-index').addClass('on');
		
	});
</script>



<%@include file="bottom.jsp"%>
